package Application;

import javax.swing.SwingUtilities;

import BLL.Model;
import Controllers.Controller;
import GUI.MapperMain;

/**
 * Main Class. Sets up MVC(Model-View-Controller) pattern.
 * 
 * @author Danny Johansen, Didzis Petkus, Liviu Berheci.
 */
public class Mapper {

	/**
	 * Creates and sets up the main window on the new event-dispatching thread.
	 * 
	 * @param args
	 *            the command line arguments
	 */
	public static void main(String[] args) {
		SwingUtilities.invokeLater(new Runnable() {
			@Override
			public void run() {
				MapperMain mainGUI = new MapperMain("This is title :)");
				Controller controller = new Controller(mainGUI, Model
						.getInstance());

				Model.getInstance().addObserver(mainGUI);
			}
		});
	}
}
